package webgamemaker.FightCanvas;

import com.google.gwt.event.dom.client.ClickEvent;
import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.event.dom.client.HandlesAllKeyEvents;
import com.google.gwt.event.dom.client.KeyPressEvent;
import com.google.gwt.event.dom.client.KeyPressHandler;
import com.google.gwt.event.dom.client.MouseDownEvent;
import com.google.gwt.event.dom.client.MouseDownHandler;
import com.google.gwt.event.shared.GwtEvent;
import com.google.gwt.user.client.ui.AbsolutePanel;
import com.google.gwt.user.client.ui.FocusPanel;

public class FightWindow extends FocusPanel 
{
	public FightCanvas fightCanvas;
	public FightBottomBar fightBottomBar;
	
	public FightWindow()
	{
		AbsolutePanel absolutePanel = new AbsolutePanel();
		absolutePanel.setSize("100%", "100%");
		add(absolutePanel);
		fightCanvas = new FightCanvas();
		fightCanvas.setSize("100%", "100%");
		absolutePanel.add(fightCanvas,0,0);
		fightBottomBar = new FightBottomBar(this);
		fightBottomBar.setSize("100%", "200px");
		absolutePanel.add(fightBottomBar,0,400);
		this.addKeyPressHandler(new KeyPressHandler()
			{
				public void onKeyPress(KeyPressEvent event) 
				{
					System.out.println("test : "+event.getCharCode());
				}
			});		
	}
}
